﻿///////////////////////////////////////////////////////////////////////////////
// 文件名： Render.hpp
// 作者：   671643387@qq.com
// 日期：   2015年11月1日 下午6:13:19
// 简介：   
///////////////////////////////////////////////////////////////////////////////

#if !defined(GRAPHICS_RENDER_RENDER_HPP_)
#define GRAPHICS_RENDER_RENDER_HPP_

#if defined(_MSC_VER) && (_MSC_VER >= 1200)
# pragma once
#endif

#include <boost/noncopyable.hpp>
#include <boost/shared_ptr.hpp>

#include <graphics/Type.hpp>
#include <graphics/EventDelegate.hpp>
#include <graphics/graphics/Scene.hpp>
#include <graphics/graphics/render/RenderWindow.hpp>
#include <graphics/graphics/scenenode/Camera.hpp>
#include <graphics/graphics/component/MeshRenderer.hpp>

namespace graphics
{
    namespace graphics
    {
        namespace render
        {
            class Render : public boost::noncopyable
            {
            public:
                Render(void){}
                virtual ~Render(void){}

            public:
                virtual bool Initialize(void) = 0;
                virtual void Shutdown(void) = 0;
                virtual void SetEventDelegate(::graphics::EventDelegate* delegate) = 0;
                virtual void SetScene(::graphics::graphics::ScenePtr scene) = 0;
                virtual bool BeginFrame(void) = 0;
                virtual void EndFrame(void) = 0;
                virtual void RenderFrame(void) = 0;
                virtual void ClearColor(::graphics::byte r, ::graphics::byte g, ::graphics::byte b, ::graphics::byte a) = 0;
                virtual void UseCamera(::graphics::graphics::scenenode::Camera::stProperties& properties) = 0;
                virtual ::graphics::graphics::component::BufferPtr CreateBuffer(::graphics::graphics::component::MeshRenderer::stProperties& properties) = 0;
            };

            typedef boost::shared_ptr<Render> RenderPtr;
        }
    }
}

#endif //GRAPHICS_RENDER_RENDER_HPP_
